package com.guchenbo.study.mvc.servlet31.springboot.jar;

import org.springframework.web.bind.annotation.ResponseBody;

import javax.annotation.Resource;
import javax.servlet.http.HttpServletResponse;

/**
 * @Author guchenbo
 * @Date 2019/11/30.
 */
//@Controller
//@RequestMapping(value = "/study2")
public class StudyController2 {
    @Resource
    private StudyService studyService;

    public StudyController2() {
    }

    @ResponseBody
    public String ok(HttpServletResponse response, String a, Integer b, User user) {
        System.out.println("in study controller2");
        studyService.demo();
        System.out.println(a);
        System.out.println(b);
        System.out.println(user);
        if (user != null) {
            System.out.println(user.getName());
            System.out.println(user.getAge());
            System.out.println(user.getAge2());
        }
        return "SpringBoot Servlet 3.0 jar ok";
    }
}
